<?php

class Expression_Operator_Separator extends Expression_Operator {
	
	public function evaluate() {
		foreach ($this->_children as $child) {
			$this->build($this->invokeLeaf($child));
		}
		return $this->compile();
	}
	
	protected function build($text) {
		parent::build($text . $this->getOperator());
	}
	
	protected function compile() {
		return trim(parent::compile(), ",");
	}
}
?>